package com.zpself.module.basic.文件读取;

import java.io.File;

/**
 * @author By ZengPeng
 * @Description
 * @date in  2020/7/15 15:47
 * @Modified By
 */
public class ReadFileList {
    public static void main(String[] args) {
        File file = new File("C:\\lib2");
        if(file.isDirectory()){
            File[] files = file.listFiles();
            assert files != null;
            for (File file1 : files) {
                System.out.println(file1.getName());
            }
        }
    }
}
